{{ template "layout/header" .}}
<main id="body">
    <div class="container">
        <div class="btn-group mb-3 d-lg-none" role="group" id="my_mobile_nav">
            <a role="button" class="btn btn-secondary" data-active="menu-my" href="/my.html">个人资料</a>
            <a role="button" class="btn btn-secondary active" data-active="menu-my-thread"
                href="/my_thread.html">论坛帖子</a>
            <a role="button" class="btn btn-secondary" data-active="menu-my-notice" href="?my-notice.htm">消息</a>
        </div>
        <div class="row">
            <!-- 左侧菜单 -->
            <div class="col-lg-2 hidden-md hidden-sm" id="my_aside">
                <div class="card">
                    <div class="card-body text-center">
                        <img class="avatar-4" src="{{.sessions.Useravatar}}">
                        <br>{{.sessions.Username}}
                    </div>
                    <div class="list-group list-group-flush text-center">
                        <a href="/my.html" class="list-group-item list-group-item-action" data-active="menu-my">个人资料</a>
                        <a href="/my_thread.html" class="list-group-item list-group-item-action active"
                            data-active="menu-my-thread">论坛帖子</a>
                        <a href="?my-notice.htm" class="list-group-item list-group-item-action"
                            data-active="menu-my-notice">消息</a>
                    </div>
                </div>
            </div>
            <!-- 右侧内容 -->
            <div class="col-lg-10" id="my_main">
                <div class="card">
                    <div class="card-header">
                        <ul class="nav nav-tabs card-header-tabs">
                            <li class="nav-item">
                                <a class="nav-link" href="/my_thread.html" data-active="my-thread">主题</a>
                            </li>
                            <li class="nav-item">
                                <a class="nav-link" href="/my_favorite.html" data-active="my-favorite">收藏 </a>
                            </li>
                            <li class="nav-item">
                                <a class="nav-link" href="/my_digest.html" data-active="my-digest">精华</a>
                            </li>
                            <li class="nav-item">
                                <a class="nav-link active" href="/my_post.html" data-active="my-post">帖子</a>
                            </li>
                        </ul>
                    </div>
                    <div class="card-body">
                        <ul class="list-unstyled postlist mb-0">


                            {{range .posts}}
                            <li class="media post" data-pid="8" data-uid="2">
                                <a href="?user-2.htm" class="mr-3" tabindex="-1">
                                    <img class="avatar-3" src="{{.Thread.User.Avatar}}">
                                </a>
                                <div class="media-body">
                                    <div class="d-flex justify-content-between small text-muted">
                                        <div>
                                            <span style="padding-bottom:0;margin-bottom:0;color:; ">
                                                <i class="iconfont icon-v1" style="font-size: !important;">
                                                    {{.Thread.User.Group.Name}}</i>
                                            </span>
                                            <span class="username">
                                                <a href="?user-2.htm"
                                                    class="text-muted font-weight-bold">{{.Thread.User.Username}}</a>
                                            </span>
                                            <span
                                                class="date text-grey ml-2">{{.Thread.CreatedAt.Unix | strtime}}</span>
                                        </div>
                                        <div class="text-right text-grey">
                                            <style>
                                                .haya-post-like .haya-post-like-loved {
                                                    color: var(--secondary) !important;
                                                }
                                            </style>
                                            <span class="haya-post-like mr-3">
                                                <a href="javascript:;" class="text-muted js-haya-post-like-post-add"
                                                    data-pid="8" title="点赞回复">
                                                    <i class="icon icon-thumbs-o-up" aria-label="点赞回复"></i>
                                                    <span class="haya-post-like-post-user-count">0</span>
                                                </a>
                                            </span>
                                            <a href="?post-update-8.htm" class="text-grey post_update mr-3"><i
                                                    class="icon-edit" title="编辑"></i> <span class="d-none">编辑</span></a>
                                            <a data-href="?post-delete-8.htm" data-confirm-text="确定删除吗？"
                                                href="javascript:void(0);"
                                                class="text-grey post_delete _confirm mr-3"><i class="icon-remove"
                                                    title="删除"></i> <span class="d-none">删除</span></a>
                                        </div>
                                    </div>
                                    <div class="message mt-1 break-all">
                                        <h6><a href="?thread-2.htm" target="_blank">{{.Thread.Subject}}</a></h6>
                                        <p>{{.Post.Message | unescaped}}</p>
                                    </div>
                                </div>
                            </li>
                            {{end}}
                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
</main>
{{ template "layout/footer" .}}
